package com.example.service;

import com.baomidou.mybatisplus.core.metadata.IPage;
import com.example.domain.dto.UserDTO;
import com.example.domain.entity.User;
import com.example.domain.query.UserQuery;

import java.util.List;

public interface UserService {

    User getUserByUsername(String username);

    IPage<User> getUserPage(UserQuery query);

    User getUserById(Long id);

    void addUser(UserDTO userDTO);

    void updateUser(UserDTO userDTO);

    void deleteUser(Long id);

    void batchDeleteUser(List<Long> ids);

    List<Long> getUserRoleIds(Long userId);

    void assignRoles(Long userId, List<Long> roleIds);

    void updatePassword(String oldPassword, String newPassword);
} 